<script setup>
import { computed } from "vue";
import { useStore } from "vuex";
import SvgIcon from "../svgIcon/index.vue";

const store = useStore();

const lang = computed(() => {
  return store.getters["webset/lang"];
});

const props = defineProps({
  menu: Object,
});
</script>

<template>
  <a-menu-item :key="menu.fullPath" :path="menu.path">
    <template #icon>
      <SvgIcon :name="menu.meta.icon" />
    </template>
    <span>{{ lang === "en" ? menu.meta.enTitle : menu.meta.title }}</span>
  </a-menu-item>
</template>